﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using UIDesigner.DesignContainers.Bases;

namespace UIDesigner.SurfaceProperties
{
    [Serializable()]
    public class ControlSurfaceProperties : SurfacePropertiesBase
    {
        public ControlSurfaceProperties() : base(null)
        {

        }

        public ControlSurfaceProperties(IBaseObjectControl objTargetComponent) : base(objTargetComponent)
        {
        }

        private UserControl TargetControl
        {
            get
            {
                return TargetComponent as UserControl;
            }
        }

        public override string Target
        {
            get
            {
                return this.TargetControl.Name;
            }
        }

        protected override SurfaceType SurfaceType
        {
            get
            {
                return SurfaceType.UserControl;
            }
        }

        public override object Clone()
        {
            ControlSurfaceProperties objProperties = new ControlSurfaceProperties();

            this.CopyTo(objProperties);

            return objProperties;
        }
    }
}
